package com.dfrz.household.utils;

/**
 * Create by keyan on 2021/7/29 17:47
 */
public enum ResultEnum {
    //这里可以自己定义的,方便与前端交互即可
    UNKNOWN_ERROR(-1,"未知错误"),
    SUCCESS(0,"成功"),
    USER_NOT_EXIST(-2,"用户不存在"),
    USER_IS_EXISTS(-3,"用户已存在"),
    DATA_IS_NULL(-4,"数据为空"),
    LOGIN_FAILED(-5,"登录失败"),
    NO_PERMISSIONS(-6,"没有权限"),
    VALIDATECODE_FAILS(-7,"验证码错误") ;
    private Integer code;
    private String  msg;
    ResultEnum(Integer code,String msg){
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
